package com.bdqn.ch09;

import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.mvc.AbstractController;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * HelloController 第一个 Spring MVC 控制器
 *
 * @aurhor Administrator  whs
 * @since 2024/7/24
 */
public class HelloController extends AbstractController {
    /**
     * @param request
     * @param response
     * @return
     * @throws Exception
     */
    @Override
    protected ModelAndView handleRequestInternal(HttpServletRequest request, HttpServletResponse response) throws Exception {
        System.out.println(" Spring MVC 框架搭建成功！");
        return new ModelAndView("hello");
    }
}
